package com.ruoyi.project.data.mapper;

import java.util.List;
import java.util.Map;

import com.ruoyi.project.data.domain.*;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

/**
 * 运单Mapper接口
 *
 * @author ruoyi
 * @date 2020-03-24
 */
@Repository
@Mapper
public interface TbTransportWaybillMapper
{
    /**
     * 查询运单
     *
     * @param waybillId 运单ID
     * @return 运单
     */
    public Waybill selectTbTransportWaybillById(Long waybillId);

    /**
     * 查询运单列表
     *
     * @param tbTransportWaybill 运单
     * @return 运单集合
     */
    public List<TbTransportWaybill> selectTbTransportWaybillList(TbTransportWaybill tbTransportWaybill);

    /**
     * 获取出厂图片
     * @param waybillNum
     * @return
     */
    public List<String> selectLeaveImage(String waybillNum);

    /**
     * 获取收货人
     * @param waybillNum
     * @return
     */
    public List<ReceiveUser> selectReceiveUserByWaybillNum(String waybillNum);

    /**
     * 获取驾驶员信息
     * @param waybillNum
     * @return
     */
    public Driver selectDriverByWaybillNum(String waybillNum);

    /**
     * 获取称重信息
     * @param waybillNum
     * @return
     */
    public List<WeightInformation> selectWeightByWaybillNum(String waybillNum);

    public int deleteWeightByWaybill(Long id);

    /**
     * 根据运单号判断是否超重异常
     * @param waybillNum
     * @return
     */
    public int selectCzycCountByWaybillNum(String waybillNum);

    public List<Map<String, Object>> selectWaybillExport(Long[] ids);

    public String selectLimitWeight(String axleNum);

}
